# $Id: PKGBUILD 83189 2013-01-27 20:17:17Z pierre $
# Maintainer:
# Contributor: Andrea Scarpino <andrea@archlinux.org>

pkgbase=festival-voices
pkgname=('festival-us'
	'festival-english')
pkgver=2.0.95
pkgrel=2
arch=('any')
url="http://www.cstr.ed.ac.uk/projects/festival/"
license=('custom')
depends=('festival')
source=("http://www.cstr.ed.ac.uk/downloads/festival/${pkgver}/festvox_cmu_us_awb_cg.tar.gz"
	"http://www.cstr.ed.ac.uk/downloads/festival/${pkgver}/festvox_cmu_us_rms_cg.tar.gz"
	"http://www.cstr.ed.ac.uk/downloads/festival/${pkgver}/festvox_cmu_us_slt_arctic_hts.tar.gz"
	"http://www.cstr.ed.ac.uk/downloads/festival/${pkgver}/festvox_kallpc16k.tar.gz"
	"http://www.cstr.ed.ac.uk/downloads/festival/${pkgver}/festvox_rablpc16k.tar.gz"
	'LICENSE')
md5sums=('2c14269587ad018ee93176bb44f4c38b'
	'a9514a9df32401774c074abec42ffb22'
	'34589c992851ad40737d3a1ed21ded49'
	'3869af78f473b616601cac3fa83cc14e'
	'34cb2478f5b8fa1ed02f5cbb496c1dcd'
	'eb7167e849fbd166699eef79e87a7e36')

package_festival-us() {
  pkgdesc="American Male/Female and Scottish English Male speaker"
  replaces=('festival-awb-arctic')

  cd ${srcdir}
  install -d "${pkgdir}/usr/share/festival/voices/"
  cp -rf festival/lib/voices/us "${pkgdir}/usr/share/festival/voices/"
  install -Dm644 "${srcdir}/LICENSE" "${pkgdir}/usr/share/licenses/festival-us/LICENSE"
}

package_festival-english() {
  pkgdesc="British and American English Male speaker"
  replaces=('festival-kallpc16k' 'festival-rablpc16k')

  cd ${srcdir}
  install -d "${pkgdir}/usr/share/festival/voices/"
  cp -rf festival/lib/voices/english "${pkgdir}/usr/share/festival/voices/"
  install -Dm644 "${srcdir}/LICENSE" "${pkgdir}/usr/share/licenses/festival-english/LICENSE"
}
